#define _CRT_SECURE_NO_WARNINGS
#include<iostream>
using namespace std;
int firstUniqChar(string s) {
    int hash[26] = { 0 };
    for (auto& n : s) {
        hash[n - 'a']++;
    }
    int dex = 0;
    for (auto& n : s) {
        if (hash[n - 'a'] == 1) {
            return ;
        }
        dex++;
    }
    return -1;
}
int main() {
    firstUniqChar("loveleetcode");
    return 0;
}